package com.css.bjdt_core.util;

public class Constants {
	//查询所有儿子不包括自己
	public static final String QUERY_CHILD_WITHOUT_SELF = "select t.dzzid as code,t.dzzjc as sname,t.dzzmc as fname,t.sjdzzid as pcode,t.zzlb as zzlb from t_m_zzinfo t where (zt='Y' or zt is null) and sjdzzid = @unitId";
	//查询所有儿子包括自己
	public static final String QUERY_CHILD = "select t.dzzid as code,t.dzzjc as sname,t.dzzmc as fname,t.sjdzzid as pcode,t.zzlb as zzlb from t_m_zzinfo t where (zt='Y' or zt is null) and (sjdzzid = @unitId or dzzid = @unitId)";
	//查询所有后代包括自己
	public static final String QUERY_ALL_CHILD = "select t.dzzid as code,t.dzzjc as sname,t.dzzmc as fname,t.sjdzzid as pcode,t.zzlb as zzlb from t_m_zzinfo t where (t.zt='Y' or t.zt is null) start with t.dzzid = @unitId connect by prior t.dzzid =t.sjdzzid";
	//查询党组织类别是党委和工委的党组织
	public static final String QUERY_BY_TYPE = "select t.dmlevcod from T_DM_ZB62_PZJGLB t where t.dmcpt like '%党委%' or t.dmcpt like '%工委%'";
}
